package communication;

/**
 * 使用两个线程交替打印 1 - 100
 */
public class TakeTurnsTest {
    public static void main(String[] args) {
        PrintNumber pn = new PrintNumber();

        Thread thread1 = new Thread(pn, "线程1");
        Thread thread2 = new Thread(pn, "线程2");
        thread1.start();
        thread2.start();

    }
}
